import request from "@/router/axios";
import { baseUrl } from "@/config/env";

// 添加班级
export function addClass(data) {
  return request({
    url: baseUrl + "/pc/stu-class",
    method: "post",
    data
  });
}

//获取班级
export function getClass(data) {
  return request({
    url: baseUrl + "/pc/stu-class",
    method: "get",
    params: data
  });
}

//删除班级
export function deleteClass(data) {
  return request({
    url: baseUrl + "/pc/stu-class",
    method: "delete",
    data
  });
}

//更新班级
export function updateClass(data) {
  return request({
    url: baseUrl + "/pc/stu-class",
    method: "put",
    data
  });
}

//远程搜索班级
export function searchClass(data) {
  return request({
    url: baseUrl + "/pc/stu-class/byName",
    method: "get",
    data
  });
}